<div class="row">
    <div class="col-sm-20">
        <h1 class="pagetitle" translate lib="web">formresource</h1>
    </div>
</div>

<pre ng-show="ErrorMessage!=null">{{ ErrorMessage }}</pre>
<div ng-show="ctrl.errormessage != ''"" class=" alert alert-danger" role="alert">{{ctrl.errormessage}}</div>
<form ng-submit="ctrl.submit()" class="form-horizontal" role="form" autocomplete="off">

    <div class="form-group">
        <label for="provider" class="col-sm-2 control-label" translate lib="web">collection</label>
        <div class="col-sm-4">
            <select id="menucollections" ng-model="ctrl.model.collection"
            ng-options="item.name as item.name for item in ctrl.collections">
          </select>
        </div>
    </div>
    <div class="form-group">
        <label for="name" class="col-sm-2 control-label" translate lib="web">name</label>
        <div class="col-sm-4">
            <input ng-model="ctrl.model.name" class="form-control input-md" ng-disabled="ctrl.loading==true" />
        </div>
    </div>
    <div class="form-group">
        <label for="id" class="col-sm-2 control-label" translate lib="web">aggregates</label>
        <div class="col-sm-4">
            <textarea json-text class='form-control' rows='1' data-min-rows='1' ng-model="ctrl.model.aggregates"
            ng-disabled="ctrl.loading==true"></textarea>
        </div>
    </div>
    <div class="form-group">
        <div class="col-sm-offset-2 col-sm-10">
            <button type="submit" ng-disabled="ctrl.loading==true" class="btn btn-success" translate
                lib="web">Save</button>
        </div>
    </div>

</form>